package client.domainModels.NodeImpl;

import java.util.ArrayList;

import client.domainModels.Node.Node;

/**
*
* @author Wei WANG
*/
public class Actor extends AbstractNode {

	private static ArrayList<String> history = new ArrayList<String>();
	
	@Override
	public String[] getChildNodeNames() {
		String[] strings = {};
		return strings;
	}

	@Override
	public String[] getNodeAttributes() {
		String[] strings = {"name"};
		return strings;
	}

	@Override
	public String toString() {
		return "Actor: "+getID();
	}

	@Override
	public String getStringRepresentation() {
		// TODO Auto-generated method stub
		return "      <actor name='" + getID()+"'/>\n";
	}

	public void addRecordInHistory(String s){
		if(history.indexOf(s)==-1){
			history.add(s);
		}
	}
	
	public ArrayList<String> getHistoryList(){
		return history;
	}
	
	public String[] getHistorySet(){
		return (String[]) history.toArray();
	}

	@Override
	public String getRep() {
		// TODO Auto-generated method stub
		return this.getID();
	}
	

	
}
